package ${domain}.action.api.wsys;

import ${domain}.frame.auth.LocalData;
import ${domain}.module.wsys.mgr.TokensManager;
import ${domain}.module.wsys.mgr.UserManager;
import ${domain}.module.wsys.req.UserLoginRequest;
import ${domain}.module.wsys.rsp.UserLoginResponse;
import org.springframework.beans.factory.annotation.Autowired;

import javax.servlet.http.HttpServletRequest;

public class UserApi {

    @Autowired
    private TokensManager tokensManager;
    @Autowired
    private UserManager userManager;

    public UserLoginResponse login(UserLoginRequest request, HttpServletRequest httpServletRequest) {
        return userManager.login(request, LocalData.getToken());
    }
}
